import request from '@/utils/request'
import { makeFormData } from '@/utils/util'

const api = {
  list: 'crm/web/product/page'
}

export function addProductSolution (data = {}) {
  return request({
    url: 'crm/fin/product_solution',
    method: 'post',
    data: makeFormData(data)
  })
}

export function getProductSolution (params = {}) {
  return request({
    url: 'crm/fin/product_solution',
    method: 'get',
    params
  })
}

export function delProductSolution (params = {}) {
  return request({
    url: 'crm/fin/product_solution',
    method: 'delete',
    params
  })
}

export function productList (params = {}) {
  return request({
    url: api.list,
    method: 'get',
    params
  })
}
